<?php
 $template="temp1";
 $arr=explode('/',$_GET["q"]);
$id=end(explode('-',end($arr)));
 if($arr[0]=='')
 {
 $page="index";
 }
 else
 {
  $page=$arr[0];
 }
 //sfdfsydrsedyjfgsjyhfdsfsdfgdgdfgdfgfg
 include 'pages/'.$page.'.php';

?>